import requests

headers ={
    'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36',
    'Referer':'https://www.bilibili.com/video/BV1dr4y1d7N6/?spm_id_from=333.337.search-card.all.click'
}

urlws ='https://upos-sz-mirrorcos.bilivideo.com/upgcxcode/28/67/1240206728/1240206728-1-100022.m4s?e=ig8euxZM2rNcNbdlhoNvNC8BqJIzNbfqXBvEqxTEto8BTrNvN0GvT90W5JZMkX_YN0MvXg8gNEV4NC8xNEV4N03eN0B5tZlqNxTEto8BTrNvNeZVuJ10Kj_g2UB02J0mN0B5tZlqNCNEto8BTrNvNC7MTX502C8f2jmMQJ6mqF2fka1mqx6gqj0eN0B599M=&uipk=5&nbs=1&deadline=1726575578&gen=playurlv2&os=cosbv&oi=0&trid=60053e64bd8c443abd52d27e592bf2c7u&mid=0&platform=pc&og=cos&upsig=2fb4890eb4a9500ace909b3c0f8ce944&uparams=e,uipk,nbs,deadline,gen,os,oi,trid,mid,platform,og&bvc=vod&nettype=0&orderid=0,3&buvid=9C19BB61-E414-8381-03EA-ED9B9245B86503646infoc&build=0&f=u_0_0&agrr=1&bw=31176&logo=80000000'
urlwy ='https://upos-sz-mirrorcos.bilivideo.com/upgcxcode/28/67/1240206728/1240206728-1-30216.m4s?e=ig8euxZM2rNcNbdlhoNvNC8BqJIzNbfqXBvEqxTEto8BTrNvN0GvT90W5JZMkX_YN0MvXg8gNEV4NC8xNEV4N03eN0B5tZlqNxTEto8BTrNvNeZVuJ10Kj_g2UB02J0mN0B5tZlqNCNEto8BTrNvNC7MTX502C8f2jmMQJ6mqF2fka1mqx6gqj0eN0B599M=&uipk=5&nbs=1&deadline=1726575578&gen=playurlv2&os=cosbv&oi=0&trid=60053e64bd8c443abd52d27e592bf2c7u&mid=0&platform=pc&og=cos&upsig=adce5c35342b98e0921cf1c974482e4f&uparams=e,uipk,nbs,deadline,gen,os,oi,trid,mid,platform,og&bvc=vod&nettype=0&orderid=0,3&buvid=9C19BB61-E414-8381-03EA-ED9B9245B86503646infoc&build=0&f=u_0_0&agrr=1&bw=5736&logo=80000000'

with open('wxs.mp4','wb') as f:
    response = requests.get(url=urlws, headers=headers)
    f.write(response.content)

with open('wxy.mp4','wb') as f:
    response = requests.get(url=urlwy, headers=headers)
    f.write(response.content)



